package com.zzyl.mapper;

import com.zzyl.entity.RoleResource;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Set;

@Mapper
public interface RoleResourceMapper {

    //查询与角色关联的资源编号
    Set<String> selectResourceNoByRoleId(@Param("roleId") Long roleId);

    //根据角色id删除关联的资源编号
    void deleteResourceByRoleId(@Param("roleId") Long roleId);

    //批量添加角色资源关系
    void insertRoleResource(@Param("list") List<RoleResource> roleResources);
}
